package com.sc.nft.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.sc.nft.entity.UserEcologyReforgeRecordsDetails;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.sc.nft.entity.vo.ecology.UserExpendRecordsPageVO;
import com.sc.nft.entity.vo.ecology.UserReforgeExpendRecordsPageVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

/**
 * 生态-重铸-用户记录表-主表(sc_user_ecology_reforge_records_details)数据Mapper
 *
 * @author Sun
 * @description 由 Mybatisplus Code Generator 创建
 * @since 2024-06-15 11:03:13
 */
@Mapper
public interface UserEcologyReforgeRecordsDetailsMapper extends BaseMapper<UserEcologyReforgeRecordsDetails> {

    Page<UserReforgeExpendRecordsPageVO> expendRecordsPage(Page page, @Param("userId") Long userId,@Param("userCreatorId") Long userCreatorId);

    /**
     * 获取用户已经使用的免费重铸次数
     *
     * @param userId
     * @param collectionId
     * @return
     */
    Integer getUseFreeCount(@Param("userId") Long userId, @Param("collectionId") Long collectionId);
}
